package action

import (
	"core/corestruct"
	"core/coreutil"
	"ht/api/htmenu/data"
	"ht/api/htmenu/service"
	"ht/htinfo"
	"reflect"
)

type InsertInitAction struct {
}

func (p *InsertInitAction) Do(mm *data.HtMenuInsertQto, ctx *corestruct.HttpContext) (*data.HtMenuDto, error) {
	return service.MainService.InsertInit(mm, ctx)
}

func InsertInitActionInit() {

	var mact = &InsertInitAction{}
	var maction = corestruct.Action{
		Method: "get",

		FullUrl: URLPrev + "/InsertInit",
		Name:    "新增" + PAGEName + "初始化",
		Ename:   "",
		Memo:    "",

		PinType:    "",
		PinIslist:  false,
		PoutType:   "",
		PoutIslist: false,
		PoutIspage: false,

		AuthType: corestruct.AuthType_Login,

		LogNeed:     false,
		LogPin:      false,
		LogPout:     false,
		LogTemplete: "",

		PrjName: htinfo.PRJ_NAME,

		Value: reflect.ValueOf(mact),
	}
	coreutil.ActionUtil.Add(maction)

}
